filterToOption

inline fun filterToOption(predicate: (L) -> Boolean): Option<Either<L, R>>

Returns Some containing the same Left if the predicate is satisfied for the value. Otherwise returns None.

Return

Some containing the same Left if the predicate is satisfied for the value. Otherwise returns None.

Parameters

predicate

Predicate function.